package model

type ErrorLog struct {
	Id        int64  `json:"id"`
	PastureId int64  `json:"pasture_id"`
	Name      string `json:"name"`
	Message   string `json:"message"`
	CreatedAt int64  `json:"created_at"`
	UpdatedAt int64  `json:"updated_at"`
}

func (e *ErrorLog) TableName() string {
	return "d_error_log"
}

func NewErrorLog(pastureId int64, name string, body string) *ErrorLog {
	return &ErrorLog{
		PastureId: pastureId,
		Name:      name,
		Message:   body,
	}
}
